package QueueDemo;

public class QueueTest {
        public static void main(String[] args) {
            ArrayQueue queue = new ArrayQueue(5);
            queue.enqueue(10);
            queue.enqueue(20);
            queue.enqueue(30);
            queue.display();
            queue.dequeue();
            queue.display();
            queue.enqueue(40);
            queue.enqueue(50);
            queue.display();
            queue.dequeue();
            queue.dequeue();
            queue.display();
            System.out.println("当前队列首元素为：" + queue.peek());
        }
}
